Virtual mac address system and method

ABSTRACT

A method for creating a virtual MAC address, the method includes receiving an Internet Protocol address that is to be associated with a virtual MAC address. The method creates a virtual MAC address by setting an OUI portion of the virtual MAC address to an OUI value and setting the non-OUI portion of the virtual MAC address to a subset of the Internet Protocol (IP) address. In one embodiment, the lower three bytes of the IP address are used. Additionally, a method of migrating a virtual MAC address includes detecting a migration event on a first system; creating a virtual MAC address on a second system; and issuing a gratuitous ARP packet containing the virtual MAC address.

RELATED FILES

This invention is related to application Ser. No. ______, filed Apr. 11, 2002, entitled “METHOD AND APPARATUS FOR SUPPORTING COMMUNICATIONS BETWEEN NODES OPERATING IN A MASTER-SLAVE CONFIGURATION” (Attorney Docket No.: 1370.012US2), which is a continuation of application Ser. No. 09/949,182, filed Sep. 7, 2001, entitled “METHOD AND APPARATUS FOR SUPPORTING COMMUNICATIONS BETWEEN NODES OPERATING IN A MASTER-SLAVE CONFIGURATION” (Attorney Docket No.: 1370.012US1), application Ser. No. 10/094,552, filed Mar. 7, 2002, entitled “METHOD AND APPARATUS FOR EXCHANGING HEARTBEAT MESSAGES AND CONFIGURATION INFORMATION BETWEEN NODES OPERATING IN A MASTER-SLAVE CONFIGURATION” (Attorney Docket No.: 1370.013US1), application Ser. No. ______, filed even date herewith, entitled “METHOD AND APPARATUS FOR CONFIGURING NODES AS MASTERS OR SLAVES” (Attorney Docket No.: 1370.014US1), application Ser. No. ______, filed even date herewith, entitled “METHOD AND APPARATUS FOR TERMINATING APPLICATIONS IN A HIGH-AVAILABILITY NETWORK”, (Attorney Docket No.: 1370.015US1), application Ser. No. ______, filed even date herewith, entitled “SCSI-BASED STORAGE AREA NETWORK” (Attorney Docket No.: 1370.021US1), application Ser. No. ______, filed even date herewith, entitled “VIRTUAL SCSI BUS FOR SCSI-BASED STORAGE AREA NETWORK” (Attorney Docket No.: 1370.022US1), application Ser. No. ______, filed even date herewith, entitled “METHOD AND APPARATUS FOR ASSOCIATING AN IP ADDRESS AND INTERFACE TO A SCSI ROUTING INSTANCE” (Attorney Docket No.: 1370.025US1); application Ser. No. ______, filed even date herewith, entitled “METHOD AND APPARATUS FOR EXCHANGING CONFIGURATION INFORMATION BETWEEN NODES OPERATING IN A MASTER-SLAVE CONFIGURATION” (Attorney Docket No.: 1370.027US1), provisional application Ser. No. ______, filed even date herewith, entitled “INTERNET PROTOCOL CONNECTED STORAGE AREA NETWORK” (Attorney Docket No.: 1370.028PRV), and application Ser. No. ______, filed even date herewith, entitled “SESSION-BASED TARGET/LUN MAPPING FOR A STORAGE AREA NETWORK AND ASSOCIATED METHOD” (Attorney Docket No.: 1370.029US1), all of the above of which are hereby incorporated by reference.

FIELD

The present invention relates generally to network addressing, and more particularly to creating a virtual MAC address.

COPYRIGHT NOTICE/PERMISSION

A portion of the disclosure of this patent document contains material that is subject to copyright protection. The copyright owner has no objection to the facsimile reproduction by anyone of the patent document or the patent disclosure as it appears in the Patent and Trademark Office patent file or records, but otherwise reserves all copyright rights whatsoever. The following notice applies to the software and data as described below and in the drawings hereto: Copyright© 2002, Cisco Systems, Inc. All Rights Reserved.

BACKGROUND

When network interface cards were first developed, each card was assigned a unique MAC (Media Access Control) address that was “burned” into the memory of the interface card. Modern network interface cards support the ability to dynamically assign MAC addresses.

Many modern network interfaces support the dynamic assignment of MAC addresses. This ability has proven useful in high availability/fault tolerant applications, many of which use the ability to assign a MAC address in order to migrate a MAC address from one interface to another. One example of such usage is described in RFC 2338 from the Internet Engineering Task Force entitled “Virtual Router Redundancy Protocol” (VRRP). RFC 2338 defines a mechanism for providing virtual router IP addresses on a LAN to be used as the default first hop router by end-hosts. The advantage gained from using VRRP is a higher availability default path without requiring configuration of dynamic routing or router discovery protocols on every end-host

While VRRP provides a virtual MAC address, it suffers from the problem that only 256 unique MAC addresses can be defined, which can be well short of the number required on many networks.

SUMMARY

The above-mentioned shortcomings, disadvantages and problems are addressed by the present invention, which will be understood by reading and studying the following specification.

In one embodiment of the invention, a method for creating a virtual MAC address, the method includes receiving an Internet Protocol-address that is to be associated with a virtual MAC address. The method creates a virtual MAC address by setting an OUI portion of the virtual MAC address to an OUI value and setting the non-OUI portion of the virtual MAC address to a subset of the Internet Protocol (IP) address. In one embodiment, the lower three bytes of the IP address are used.

In a further embodiment of the invention, a method of migrating a virtual MAC address includes detecting a migration event on a first system; creating a virtual MAC address on a second system; and issuing a gratuitous ARP packet containing the virtual MAC address.

The present invention describes systems, clients, servers, methods, and computer-readable media of varying scope. In addition to the aspects and advantages of the present invention described in this summary, further aspects and advantages of the invention will become apparent by reference to the drawings and by reading the detailed description that follows.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a block diagram of a storage router hardware and operating environment in which different embodiments of the invention can be practiced;

FIG. 2 is a diagram providing further details of a storage router configuration supporting high availability applications according to an embodiment of the invention;

FIG. 3 is a flowchart illustrating methods for creating a virtual MAC address according to an embodiment of the invention;

FIGS. 4A and 4B are flowcharts illustrating methods for using a virtual MAC address according to an embodiment of the invention; and

FIG. 5 is a pictorial diagram illustrating the method of FIG. 3.

DETAILED DESCRIPTION

In the following detailed description of exemplary embodiments of the invention, reference is made to the accompanying drawings which form a part hereof, and in which is shown by way of illustration specific exemplary embodiments in which the invention may be practiced. These embodiments are described in sufficient detail to enable those skilled in the art to practice the invention, and it is to be understood that other embodiments may be utilized and that logical, mechanical, electrical and other changes may be made without departing from the scope of the present invention.

Some portions of the detailed descriptions which follow are presented in terms of algorithms and symbolic representations of operations on data bits within a computer memory. These algorithmic descriptions and representations are the ways used by those skilled in the data processing arts to most effectively convey the substance of their work to others skilled in the art. An algorithm is here, and generally, conceived to be a self-consistent sequence of steps leading to a desired result. The steps are those requiring physical manipulations of physical quantities. Usually, though not necessarily, these quantities take the form of electrical or magnetic signals capable of being stored, transferred, combined, compared, and otherwise manipulated. It has proven convenient at times, principally for reasons of common usage, to refer to these signals as bits, values, elements, symbols, characters, terms, numbers, or the like. It should be borne in mind, however, that all of these and similar terms are to be associated with the appropriate physical quantities and are merely convenient labels applied to these quantities. Unless specifically stated otherwise as apparent from the following discussions, terms such as “processing” or “computing” or “calculating” or “determining” or “displaying” or the like, refer to the action and processes of a computer system, or similar computing device, that manipulates and transforms data represented as physical (e.g., electronic) quantities within the computer system's registers and memories into other data similarly represented as physical quantities within the computer system memories or registers or other such information storage, transmission or display devices.

In the Figures, the same reference number is used throughout to refer to an identical component which appears in multiple Figures. Signals and connections may be referred to by the same reference number or label, and the actual meaning will be clear from its use in the context of the description.

The following detailed description is, therefore, not to be taken in a limiting sense, and the scope of the present invention is defined only by the appended claims.

OPERATING ENVIRONMENT

Some embodiments of the invention operate in an environment of systems and methods that provide a means for fibre-channel bases SANs to be accessed from TCP/IP network hosts. FIG. 1 is a block diagram describing the major components of such a system. Storage router system 100 includes computers (127, 128) connected through an IP network 129 to storage router 110. Storage router 110 is connected in turn through storage network 130 to one or more SCSI devices 140. In the embodiment shown in FIG. 3, storage router 110 includes an iSCSI interface 104, a SCSI router 105 and a SCSI interface 106. iSCSI interface 104 receives encapsulated SCSI packets from IP network 129, extracts the SCSI packet and send the SCSI packet to SCSI router 105. SCSI interface 106 modifies the SCSI packet to conform with its network protocol (e.g., Fibre Channel, parallel SCSI, or iSCSI) and places the modified SCSI packet onto storage network 130. The SCSI packet is then delivered to its designated SCSI device 140.

In one embodiment, storage router 110 provides IPv4 router functionality between a single Gigabit Ethernet and a Fibre Channel interface. In one such embodiment, static routes are supported. In addition, storage router 110 supports a configurable MTU size for each interface, and has the ability to reassemble and refragment IP packets based on the MTU of the destination interface.

In one embodiment, storage router 110 acts as a gateway, converting SCSI protocol between Fibre Channel and TCP/IP. Storage router 110 is configured in such an embodiment to present Fibre Channel devices as iSCSI targets, providing the ability for clients on the IP network to directly access storage devices.

In one embodiment, SCSI routing occurs in the Storage Router 110 through the mapping of physical storage devices to iSCSI targets. An iSCSI target (also called logical target) is an arbitrary name for a group of physical storage devices. You can map an iSCSI target to multiple physical devices. An iSCSI target always contains at least one Logical Unit Number (LUN). Each LUN on an iSCSI target is mapped to a single LUN on a physical storage target.

FIG. 2 shows a sample storage router network 200. Servers 127-128 with iSCSI drivers access the storage routers 110 through an IP network 129 connected to the Gigabit Ethernet interface 104 of each storage router 110. The storage routers 110 access storage devices 140 through a storage network 138 connected to the Fibre Channel interface 106 of each storage router 110. A management station 210 manages the storage routers 110 through an IP network 159 connected to the management interface 158 and/or 168 of each storage router. For high-availability operation, the storage routers 110 communicate with each other over two networks: the HA network 149 connected to the HA interface 148 of each storage router 110, and the management network 159 connected to the management interface 158 and/or 168 of each storage router 110.

In some embodiments of the invention, SCSI router applications 105 are configured with their own TCP/IP address. Further, in some embodiments, Gigabit Ethernet interface 104 supports the ability to assign multiple MAC (Media Access Control) addresses. As is known in the art, MAC addresses are 48 bits in length and are expressed as 12 hexadecimal digits. The first 6 hexadecimal digits, which are administered by the IEEE, identify the manufacturer or vendor and thus comprise the Organizational Unique Identifier (OUI). The last 6 hexadecimal digits comprise the interface serial number. Thus the system may associate a uniquely created virtual MAC address for each instance of a SCSI router 105.

Further details on the operation of the above describe system, including high availability embodiments can be found in application Ser. No. ______, entitled “METHOD AND APPARATUS FOR EXCHANGING HEARTBEAT MESSAGES AND CONFIGURATION INFORMATION BETWEEN NODES OPERATING IN A MASTER-SLAVE CONFIGURATION” (Attorney Docket No.: 1370.013US1), application Ser. No. ______, entitled “METHOD AND APPARATUS FOR CONFIGURING NODES AS MASTERS OR SLAVES” (Attorney Docket No.: 1370.014US1), application Ser. No. ______, entitled “METHOD AND APPARATUS FOR TERMINATING APPLICATIONS IN A HIGH-AVAILABILITY NETWORK”, (Attorney Docket No.: 1370.015US1), application Ser. No. ______, entitled “SCSI-BASED STORAGE AREA NETWORK” (Attorney Docket No.: 1370.021US1), application Ser. No. ______, entitled “VIRTUAL SCSI BUS FOR SCSI-BASED STORAGE AREA NETWORK” (Attorney Docket No.: 1370.022US1), application Ser. No. ______, entitled “METHOD AND APPARATUS FOR ASSOCIATING AN IP ADDRESS AND INTERFACE TO A SCSI ROUTING INSTANCE” (Attorney Docket No.: 1370.025US1); application Ser. No. ______, entitled “METHOD AND APPARATUS FOR EXCHANGING CONFIGURATION INFORMATION BETWEEN NODES OPERATING IN A MASTER-SLAVE CONFIGURATION” (Attorney Docket No.: 1370.027US1), and provisional application Ser. No. ______, entitled “INTERNET PROTOCOL CONNECTED STORAGE AREA NETWORK” (Attorney Docket No.: 1370.028PRV), all of which have been previously incorporated by reference.

FIG. 3 illustrates a method for creating a virtual MAC address according to an embodiment of the invention. A system desiring to create a virtual MAC address begins by receiving an IP address that is to be associated with the desired virtual MAC address (block 305). The IP address can be specified as a parameter to a function that creates virtual MAC addresses. Alternatively, the IP address can be determined through configuration databases. The invention is not limited to any particular method for receiving an IP address.

A system executing the method then sets the OUI portion of the virtual MAC address (block 310). As discussed above, the OUI is used to identify a manufacturer or vendor of a network interface. In some embodiments of the invention, the “local bit” of the OUI portion of the MAC address is set. As is known in the art, the local bit is intended to indicate that the MAC address need only be unique on network segments reachable through the network interface.

Next, a system executing the method sets the non-OUI portion (i.e. the serial number portion) of the MAC address to a subset of the IP address received above (block 315). In some embodiments of the invention, the three lower order bytes of the IP address are copied to the three non-OUI bytes of the virtual MAC address.

FIG. 4A illustrates a method of using a virtual MAC address employed by some embodiments of the invention. A system executing the method, such as storage router system 100, begins by detecting a migration event (block 405). A migration event is one that requires a MAC address to be migrated from a first network interface to a second network interface. The first network interface and the second network interface may be on the same network element, or they may be on different network elements.

One example of a migration event is a failover event. In this case, some system failure causes an application to be migrated to a different system. In the case of the storage router described above in FIG. 1, a failover event can be the failure of a SCSI router application. Because each SCSI router application has an IP address associated with it, and because each IP address has a MAC associated with it, it is desirable for the MAC to migrate with the application.

Next, the virtual MAC is added to the network interface (block 415). In some embodiments, the virtual MAC is created using them method described above in FIG. 3. In particular embodiments of the invention where the network element is a storage router device in a high availability configuration, the IP address used to create the virtual MAC address will be that of an application that is failed over to a second storage router. In these embodiments, the IP address is read from a configuration database replicated on each storage router that is a member of the high availability configuration.

Finally, in some embodiments of the invention, the second network interface issues a “gratuitous” ARP packet (block 420). The packet is gratuitous in that it is not issued in response to an ARP request. The gratuitous ARP is desirable, because it causes other network elements in the network such as switches and routers to update their respective ARP tables more quickly than they would through normal address resolution mechanisms that rely on timeouts.

FIG. 4B illustrates a method for removing a virtual MAC address. The method begins with the creation of a virtual MAC address (block 402). The virtual MAC address is assigned to a network interface and will typically be associated with an application such as a SCSI router application. Next the system detects a migration event (block 405). Finally, a system executing the method next removes the virtual MAC address from the first interface (block 410). This occurs in order to prevent the first network interface from responding to subsequent ARP requests after the migration event occurs.

It should be noted that the method in FIG. 4B is a complement to the method in FIG. 4A. The method illustrated in FIG. 4B may be used when there has not been a catastrophic failure such as a system crash or power down. In the event of a catastrophic failure, the virtual MAC will have been implicitly removed by virtue of the fact that the network element is no longer functioning.

FIG. 5 provides a pictorial description of the creation of a virtual MAC address 502. Each block in FIG. 5 represents an 8-bit byte. As can bee seen from the illustration, a three-byte OUI is placed in the upper three-bytes of MAC address 502. Additionally, the lowest three bytes of the IP address 506 are copied to the lowest three bytes of the MAC address 502, resulting in an MAC address that is guaranteed to be unique on any subnet in which the IP address is valid.

It should be noted that a different number of bytes or bits of the IP address could be used and such use is within the scope of the invention.

This section has described the various software components in a system that creates virtual MAC addresses and migrates virtual MAC addresses. As those of skill in the art will appreciate, the software can be written in any of a number of programming languages known in the art, including but not limited to C/C++, Visual Basic, Smalltalk, Pascal, Ada and similar programming languages. The invention is not limited to any particular programming language for implementation.

CONCLUSION

Systems and methods creating and using a virtual MAC address are disclosed. The embodiments of the invention provide advantages over previous systems. For example, the systems and methods allow for the creation range of MAC addresses that are as unique as the IP addresses that can be defined within the system. Further, the association of an IP address with a virtual MAC address provides for the easy creation of unique virtual MAC addresses that can be easily migrated to other systems.

Although specific embodiments have been illustrated and described herein, it will be appreciated by those of ordinary skill in the art that any arrangement which is calculated to achieve the same purpose may be substituted for the specific embodiments shown. This application is intended to cover any adaptations or variations of the present invention.

The terminology used in this application is meant to include all of these environments. It is to be understood that the above description is intended to be illustrative, and not restrictive. Many other embodiments will be apparent to those of skill in the art upon reviewing the above description. Therefore, it is manifestly intended that this invention be limited only by the following claims and equivalents thereof. 

1. A method for creating a virtual MAC address, the method comprising: configuring in a configuration for a first network attached system a plurality Internet Protocol (IP) addresses for each of a plurality of applications executing on the first network attached system, wherein each of the plurality of applications is provided a different IP address; replicating the configuration to a second network attached system; creating a plurality of virtual MAC (Media Access and Control) addresses, each virtual MAC address associated with one of the different IP addresses; setting a non-OUI portion of the virtual MAC address to a subset of the Internet Protocol (IP) address associated with the virtual MAC address; detecting a migration event on the first network attached system; initializing the plurality of applications on the second network attached system according to the replicated configuration, wherein each of the plurality of applications is assigned the different IP address according to the replicated configuration; and recreating on the second network attached system the plurality of virtual MAC addresses, each virtual MAC address associated with one of the different IP addresses and each created on the second network attached system by setting a non-OUI portion of each virtual MAC address to a subset of the different Internet Protocol (IP) address associated with the virtual MAC address.
 2. The method of claim 1, further comprising setting the local bit of an OUI portion of the virtual MAC address.
 3. The method of claim 1, wherein the subset of the IP address comprises three bytes.
 4. The method of claim 1, wherein the subset of the IP address comprises a subset of the low order bytes of the IP address.
 5. The method of claim 1, further comprising removing the virtual MAC address on the first network interface to be migrated.
 6. (canceled)
 7. The method of claim 1, wherein the migration event is a failover event.
 8. A system comprising: a first network attached system having a plurality of applications, each application having a different IP address; a configuration to maintain each of the different IP addresses for the plurality of applications; a first network interface coupled to the first network attached system, the first network interface configured with a plurality of MAC addresses, wherein a MAC address of the plurality of MAC addresses is associated with the different IP address of one of the plurality of applications; and a second network attached system having a second network interface coupled to the network and operable to: receive a replicated configuration corresponding to the configuration on the first network attached system, in response to a migration event, initialize on the second network attached system the plurality of applications according to the replicated configuration, wherein each of the plurality of applications is assigned the different IP address according to the replicated configuration, and recreate on the second network attached system the plurality of virtual MAC addresses, each virtual MAC address associated with one of the different IP addresses; wherein each MAC address of the plurality of MAC addresses includes a non-OUI portion that comprises a subset of the different IP address associated with the MAC address.
 9. The system of claim 8, wherein the local bit of an OUI portion of each virtual MAC address is set.
 10. The system of claim 8, wherein the subset of the IP address comprises three bytes.
 11. The system of claim 8, wherein the subset of the IP address comprises a subset of the low order bytes of the IP address associated with the MAC address.
 12. The system of claim 8, wherein the migration event comprises a failure of one or more of the plurality of applications in the first network attached system.
 13. A computer-readable storage medium having stored thereon a method for creating a virtual MAC address, the method comprising: configuring in a configuration for a first network attached system a plurality Internet Protocol (IP) addresses for each of a plurality of applications executing on the first network attached system, wherein each of the plurality of applications is provided a different IP address; replicating the configuration to a second network attached system; creating a plurality of virtual MAC (Media Access and Control) addresses, each virtual MAC address associated with one of the different IP addresses; setting a non-OUI portion of the virtual MAC address to a subset of the Internet Protocol (IP) address-associated with the virtual MAC address; detecting a migration event on the first network attached system; initializing the plurality of applications on the second network attached system according to the replicated configuration, wherein each of the plurality of applications is assigned the different IP address according to the replicated configuration; and recreating on the second network attached system the plurality of virtual MAC addresses, each virtual MAC address associated with one of the different IP addresses and each created on the second network attached system by setting a non-OUI portion of each virtual MAC address to a subset of the different Internet Protocol (IP) address associated with the virtual MAC address.
 14. The computer-readable storage medium of claim 13, wherein the method further comprises setting the local bit of an OUI portion of the virtual MAC address.
 15. The computer-readable storage medium of claim 13, wherein the subset of the IP address comprises three bytes.
 16. The computer-readable storage medium of claim 13, wherein the subset of the IP address comprises a subset of the low order bytes of the IP address.
 17. The computer-readable storage medium of claim 13, wherein the method further comprises removing the virtual MAC address on the first network interface to be migrated.
 18. The computer-readable storage medium of claim 13, wherein the migration event is a failover event.
 19. A system comprising: means for configuring in a configuration for a first network attached system an IP address for each of a plurality of applications on the first network attached system, wherein each applications is provided a different IP address; means for replicating the configuration to a second network attached system; means for creating a plurality of virtual MAC address, each virtual MAC address associated with one of the different IP addresses; means for setting a non-OUI portion of each virtual MAC address to a subset of the different IP address associated with the virtual MAC address means for detecting a migration event on the first network attached system; means for initializing on the second network attached system the plurality of applications according to the replicated configuration, wherein each of the plurality of applications is assigned the different IP address according to the replicated configuration; and means for recreating on the second network attached system the plurality of virtual MAC addresses, each virtual MAC address associated with one of the different IP addresses and each created on the second network attached system by setting a non-OUI portion of each virtual MAC address to a subset of the different Internet Protocol (IP) address associated with the virtual MAC address. 